<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
        xmlns:h="http://java.sun.com/jsf/html"
        xmlns:f="http://java.sun.com/jsf/core"
        xmlns:ui="http://java.sun.com/jsf/facelets"
        xmlns:p="http://primefaces.org/ui">
<h:head>
	<title>Travel Dream - Home</title>
	<link href="style.css" rel="stylesheet" type="text/css" />
</h:head>
<h:body>
<div id="maincontainer">
  <div id="menu">
    <div>
    	<ul style="display:block;list-style-type:none;">
    		<li><a href="home.xhtml">HOME</a></li>
    		<li><a href="search package.xhtml">RICERCA PACCHETTO</a></li>
    		<li><a href="search component.xhtml">RICERCA COMPONENTE</a></li>
    	</ul>
    </div>
  </div>
  <div id="right_column">
<h:form>
<p:accordionPanel>  
    <p:tab title="Ricerca volo">  
        <p:panelGrid columns="2">
		<f:facet name="header">
			Ricerca Volo
		</f:facet>
		
		<h:outputLabel for="departureCity" value="Città di partenza: *" />
		<p:inputText id="departureCity" value="#{FlightSearch.flightSearch.departureCity}" label="departureCity" />
		
		<h:outputLabel for="departureAirport" value="Aeroporto di partenza: *" />
		<p:inputText id="departureAirport" value="#{FlightSearch.flightSearch.departureAirport}" label="departureAirport" />
		
		<h:outputLabel for="departureDate" value="Data di partenza: *" />
		<p:calendar id="departureDate" value="#{FlightSearch.flightSearch.departureDate}" mode="popup" label="departureDate" />
		
		<h:outputLabel for="arrivalCity" value="Città di arrivo: *" />
		<p:inputText id="arrivalCity" value="#{FlightSearch.flightSearch.arrivalCity}" label="arrivalCity" />
		
		<h:outputLabel for="arrivalAirport" value="Aeroporto di arrivo: *" />
		<p:inputText id="arrivalAirport" value="#{FlightSearch.flightSearch.arrivalAirport}" label="arrivalAirport" />
	
		</p:panelGrid>

		<h:commandButton value="Search" action="#{FlightSearch.search()}" />
		<h:commandButton value="Search all" action="#{FlightSearch.searchAll()}" />  
    </p:tab>  
    <p:tab title="Ricerca escursione">  
        <p:panelGrid columns="2">
		<f:facet name="header">
			Ricerca Escursione
		</f:facet>
		
		<h:outputLabel for="name" value="Nome: *" />
		<p:inputText id="name" value="#{ExcursionMgr.excursionManager.name}" label="name" />
		
		<h:outputLabel for="nation" value="Nazione: *" />
		<p:inputText id="nation" value="#{ExcursionMgr.excursionManager.nation}" label="nation" />
	
		</p:panelGrid>

		<h:commandButton value="Cerca" action="#{ExcursionMgr.search()}" />
		<h:commandButton value="Cerca tutti" action="#{ExcursionMgr.searchAll()}" />
    </p:tab>  
    <p:tab title="Ricerca camera">  
        <p:panelGrid columns="2">
		<f:facet name="header">
			Ricerca camere
		</f:facet>
		
		<h:outputLabel for="city" value="Città: *" />
		<p:inputText id="city" value="#{RoomMgr.roomMgr.city}" label="city" />
	
		</p:panelGrid>
		<h:commandButton value="Search" action="#{RoomMgr.search()}" />
		<h:commandButton value="Search all" action="#{RoomMgr.searchAll()}" /> 
    </p:tab>  
    <p:tab title="Ricerca hotel">  
        <p:panelGrid columns="2">
		<f:facet name="header">
			Ricerca Hotel
		</f:facet>
		
		<h:outputLabel for="name" value="Nome: *" />
		<p:inputText id="name" value="#{HotelSearch.hotelMgr.name}" label="name" />
		
		<h:outputLabel for="city" value="Città: *" />
		<p:inputText id="city" value="#{HotelSearch.hotelMgr.city}" label="city" />
		
 		</p:panelGrid>

		<h:commandButton value="Search" action="#{HotelSearch.search()}" />
		<h:commandButton value="Search all" action="#{HotelSearch.searchAll()}" /> 
    </p:tab>
</p:accordionPanel>  
 </h:form>
 </div>
 </div>
</h:body>
</html>